<?php
/**
 * Created by PhpStorm.
 * User: jz
 * Date: 16/7/13
 * Time: 上午10:24
 */
require_once ('bookmark_fns.php');
session_start();
$user = $_SESSION['valid_user'];

unset($_SESSION['valid_user']);
$result_dest = session_destroy();

do_html_header('登出');
if (!empty($user)){
    if ($result_dest){
        echo '登出成功';
        do_html_url('login.php', '登陆');
    }else {
        echo '不能登出';
    }
    
}else {
    echo '您还没有登陆,请先登陆';
    do_html_url('login.php', '登陆');
}
do_html_footer();